function pushHistory() {
    var state = {
        title: "title",
        url: "#"
    };
    window.history.pushState(state, "title", "#");
}
$(function(){
    history.pushState('forward', null, '#');
    window.addEventListener('popstate', function () {
        history.forward(1);
        top.goBack();
    });
});